import re


a = {'192.168.1.218': 'dr-xr-xr-x .\ndr-xr-xr-x ..\n-rw-r--r-- .autofsck\n-rw-r--r-- .autorelabel\ndr-xr-xr-x bin\ndr-xr-xr-x boot\ndrwxr-xr-x cgroup\ndrwxr-xr-x codeRelease\ndrwxr-xr-x dev\ndrwxr-xr-x etc\ndrwxr-xr-x gogs\ndrwxr-xr-x gogs-repositories\ndrwxr-xr-x home\ndr-xr-xr-x lib\ndr-xr-xr-x lib64\ndrwx------ lost+found\ndrwxr-xr-x media\ndrwxr-xr-x misc\ndrwxr-xr-x mnt\ndrwxr-xr-x net\n-rw------- nohup.out\ndrwxr-xr-x opt\ndr-xr-xr-x proc\ndr-xr-x--- root\ndrwxr-xr-x salt-push\ndr-xr-xr-x sbin\ndrwxr-xr-x selinux\ndrwxr-xr-x siteDir\ndrwxr-xr-x srv\ndrwxr-xr-x sys\ndrwxrwxrwt tmp\ndrwxr-xr-x usr\ndrwxr-xr-x var'}
file_list = []
dir_list = []


for i in  a['192.168.1.218'].split("\n"):
    F = i.split()

    if re.match(r"-",F[0]):
        file_list.append(F[1])

    else:
        dir_list.append(F[1])



